﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Puntos.aspx.cs" Inherits="Sitio.WebForm1" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    
        <asp:Label ID="Label1" runat="server" Text="Puntos"></asp:Label>
        <br />
        <asp:Label ID="lblMensaje" runat="server"></asp:Label>
    
    </div>
    <asp:Panel ID="pnlOp" runat="server">
        <asp:Button ID="btNuevo" runat="server" Text="Nuevo" onclick="btNuevo_Click" />
        <asp:Button ID="btBuscar" runat="server" Text="Buscar" 
            onclick="btBuscar_Click" />
    </asp:Panel>
    <asp:Panel ID="pnlNuevo" runat="server" Height="148px">
        <asp:Label ID="Label2" runat="server" Text="Ubicacion Punto:"></asp:Label>
        <asp:TextBox ID="txtUbicacionPunto" runat="server" Width="83px"></asp:TextBox>
        <br />
        <asp:Label ID="Label3" runat="server" Text="Descripcion Punto:"></asp:Label>
        <asp:TextBox ID="txtDescripcionPunto" runat="server" Width="162px"></asp:TextBox>
        <br />
        <asp:Label ID="Label4" runat="server" Text="Estado Punto:"></asp:Label>
        <br />
        <asp:CheckBox ID="CheckBox1" runat="server" Text="Activo" />
        <br />
        <asp:CheckBox ID="CheckBox2" runat="server" Text="No Activo" />
        <br />
        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        <asp:Button ID="btGuardar" runat="server" Text="Guardar" />
        <br />
        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    </asp:Panel>
    <asp:Panel ID="pnlBuscar" runat="server" Height="134px">
        <asp:GridView ID="grdPuntos" runat="server"
                onrowcommand="ResultGrid_RowCommand" 
                onselectedindexchanged="grdPuntos_SelectedIndexChanged" Width="354px" 
            AutoGenerateColumns="False" EnableModelValidation="True">
        <EmptyDataTemplate>
                    No se encontraron resultados para la busqueda.
                </EmptyDataTemplate>
                <Columns>
                    <asp:TemplateField HeaderText="Eliminar"> 
			            <ItemTemplate>
                            <asp:ImageButton runat="server" ID="Delete" ImageUrl="~/ImagenesGridView/eliminar.png" CommandName="Eliminar" CommandArgument='<%# DataBinder.Eval(Container.DataItem,"id") %>'  />
                            
			            </ItemTemplate>
		            </asp:TemplateField>
                    <asp:TemplateField HeaderText="Editar">            
			            <ItemStyle HorizontalAlign="Center"></ItemStyle>
			            <ItemTemplate>
                            <asp:ImageButton runat="server" ID="Edit" ImageUrl="~/ImagenesGridView/editar.jpg" CommandName="Editar" CommandArgument='<%# DataBinder.Eval(Container.DataItem,"id") %>' />
			            </ItemTemplate>
		            </asp:TemplateField>
                    <asp:BoundField DataField="Nombre" HeaderText="Nombre"/>
                    <asp:BoundField DataField="Descripcion" HeaderText="Descripcion"/>   
                    <asp:BoundField DataField="id" HeaderText="Codigo" Visible="false" />
                </Columns>
        
        </asp:GridView>
    </asp:Panel>
    </form>
</body>
</html>
